import uvicorn
import argparse
from app.core.config import settings

if __name__ == "__main__":
    parser = argparse.ArgumentParser(description="启动后端API服务")
    parser.add_argument("--host", type=str, default="0.0.0.0", help="监听的IP地址")
    parser.add_argument("--port", type=int, default=8000, help="监听的端口号")
    args = parser.parse_args()
    
    uvicorn.run(
        "app.main:app",
        host=args.host,
        port=args.port,
        reload=True,
        workers=1
    ) 